package com.zheng.shop.dao.model;

import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;

import java.io.Serializable;

/**
 * <p>
 * 
 * </p>
 *
 * @author likun
 * @since 2017-12-29
 */
@TableName("shop_product_image")
public class ShopProductImage extends Model<ShopProductImage> {

    private static final long serialVersionUID = 1L;

	@TableId(value="id", type= IdType.AUTO)
	private Integer id;
	@TableField("product_id")
	private Integer productId;
	@TableField("image_path")
	private String imagePath;
	@TableField("is_main")
	private Boolean isMain;


	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public Integer getProductId() {
		return productId;
	}

	public void setProductId(Integer productId) {
		this.productId = productId;
	}

	public String getImagePath() {
		return imagePath;
	}

	public void setImagePath(String imagePath) {
		this.imagePath = imagePath;
	}

	public Boolean getMain() {
		return isMain;
	}

	public void setMain(Boolean isMain) {
		this.isMain = isMain;
	}

	@Override
	protected Serializable pkVal() {
		return this.id;
	}

	@Override
	public String toString() {
		return "ShopProductImage{" +
			"id=" + id +
			", productId=" + productId +
			", imagePath=" + imagePath +
			", isMain=" + isMain +
			"}";
	}
}
